﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using TimKen.DataEntity;
using TimKen.App;
namespace TimKen.Web.Shop
{
    public partial class Order_Ship : TimKen.App.WebPage
    {
       public CommonAddress com = new CommonAddress();
       protected void Page_Load(object sender, EventArgs e)
       {
           if (!IsPostBack)
           {
               if (CurrentUserName == null || CurrentUserName == "")
               {
                   Alert("您必须登录！", "../Index.aspx");
               }
               com = Session["address"] as CommonAddress;
               Bind();
           }
       }
        public void Bind()
        {
            //Response.Redirect("当前");
          ShopCartSet shop=Session["ShopCartSet"] as ShopCartSet;
          var query = from x in shop.GetItems
                      select new
                      {
                          num = x.Value.Count,
                          Money = x.Value.Money,
                          Min = x.Value.Project.Min,
                          MinQuantitative = x.Value.Project.MinQuantitative,
                          Netweight = x.Value.Project.Netweight,
                          ProjectId = x.Value.Project.ProjectId,
                          ProjectXh = x.Value.Project.ProjectXh,
                          Unitprice = x.Value.Project.Unitprice,
                          Date = x.Value.Project.Date,
                      };
          this.Rept.DataSource = query.ToList();
          this.Rept.DataBind();
        }
    }
}